#include <func.h>

int main(int argc,char **argv)
{
    ARGS_CHECK(argc,2);
    int fd = open(argv[1],O_RDWR);
    ERROR_CHECK(fd,-1,"open");

    char buf[20] = "hello\n";
    int ret = write(fd,buf,strlen(buf));
    ERROR_CHECK(ret,-1,"write");
    printf("this is %d calling chfile\n",getuid());
    printf("my eff id is %d\n",geteuid());
    while(1);
    return 0;
}

